package com.mall.orders.common.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.mall.common.core.annotation.Excel;
import com.mall.common.core.web.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;


/**
 * 订单对象 t_orders
 *
 * @author guojie
 * @date 2025-02-14
 */
public class Orders extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键自增 */
    private Long id;

    /** 订单编号 */
    private String orderNum;

    /** 下单人 */
    private Long userId;

    /** 收货地址 */
    private String orderAddr;

    /** 用户备注 */
    private String userRemark;

    /** 下单总金额 */
    private BigDecimal totalMoney;

    /** 下单时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createDatetime;

    /** 售后状态（0-无售后 1-售后中 2-退款成功 3-售后关闭） */
    private Long afterSales;

    /** 订单状态 （0-待付款 1-待发货 2-部分发货 3-待收货 4-已完成 5-已关闭 6-售后中） */
    private Long orderStatus;

    /** 推广渠道 （0-抖音直播 1-腾讯惠聚 2-小红手订单 3-微信小店 4-支付宝商家小程序） */
    private Long promotionChannel;

    /** 订单备注 */
    private String orderRemark;

    /** 支付方式 （0-微信 1-支付宝） */
    private Long payType;

    /** 物流编号 */
    @Excel(name = "物流编号")
    private String logisticsNum;

    /** 物流公司（0-顺丰速运 1-中通 2-申通 3-圆通 4-菜鸟 5-极兔） */
    private Long logisticsId;

    /** 发货地址 */
    @Excel(name = "发货地址")
    private String shipAddr;



    private Long chargebackReason;
    private String chargebackRemark;

    public Long getChargebackReason()
    {
        return chargebackReason;
    }

    public void setChargebackReason(Long chargebackReason)
    {
        this.chargebackReason = chargebackReason;
    }

    public String getChargebackRemark()
    {
        return chargebackRemark;
    }

    public void setChargebackRemark(String chargebackRemark)
    {
        this.chargebackRemark = chargebackRemark;
    }


    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }
    public void setOrderNum(String orderNum)
    {
        this.orderNum = orderNum;
    }

    public String getOrderNum()
    {
        return orderNum;
    }
    public void setUserId(Long userId)
    {
        this.userId = userId;
    }

    public Long getUserId()
    {
        return userId;
    }
    public void setOrderAddr(String orderAddr)
    {
        this.orderAddr = orderAddr;
    }

    public String getOrderAddr()
    {
        return orderAddr;
    }
    public void setUserRemark(String userRemark)
    {
        this.userRemark = userRemark;
    }

    public String getUserRemark()
    {
        return userRemark;
    }
    public void setTotalMoney(BigDecimal totalMoney)
    {
        this.totalMoney = totalMoney;
    }

    public BigDecimal getTotalMoney()
    {
        return totalMoney;
    }
    public void setCreateDatetime(Date createDatetime)
    {
        this.createDatetime = createDatetime;
    }

    public Date getCreateDatetime()
    {
        return createDatetime;
    }
    public void setOrderStatus(Long orderStatus)
    {
        this.orderStatus = orderStatus;
    }

    public Long getOrderStatus()
    {
        return orderStatus;
    }
    public void setPromotionChannel(Long promotionChannel)
    {
        this.promotionChannel = promotionChannel;
    }

    public Long getPromotionChannel()
    {
        return promotionChannel;
    }
    public void setOrderRemark(String orderRemark)
    {
        this.orderRemark = orderRemark;
    }

    public String getOrderRemark()
    {
        return orderRemark;
    }
    public void setPayType(Long payType)
    {
        this.payType = payType;
    }

    public Long getPayType()
    {
        return payType;
    }
    public void setLogisticsNum(String logisticsNum)
    {
        this.logisticsNum = logisticsNum;
    }

    public String getLogisticsNum()
    {
        return logisticsNum;
    }

    public void setShipAddr(String shipAddr)
    {
        this.shipAddr = shipAddr;
    }

    public String getShipAddr()
    {
        return shipAddr;
    }

    public Long getLogisticsId()
    {
        return logisticsId;
    }

    public void setLogisticsId(Long logisticsId)
    {
        this.logisticsId = logisticsId;
    }

    public Long getAfterSales()
    {
        return afterSales;
    }

    public void setAfterSales(Long afterSales)
    {
        this.afterSales = afterSales;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("orderNum", getOrderNum())
            .append("userId", getUserId())
            .append("orderAddr", getOrderAddr())
            .append("userRemark", getUserRemark())
            .append("totalMoney", getTotalMoney())
            .append("createDatetime", getCreateDatetime())
            .append("afterSales", getAfterSales())
            .append("orderStatus", getOrderStatus())
            .append("promotionChannel", getPromotionChannel())
            .append("orderRemark", getOrderRemark())
            .append("payType", getPayType())
            .append("logisticsNum", getLogisticsNum())
            .append("logisticsId", getLogisticsId())
            .append("shipAddr", getShipAddr())
            .toString();
    }

}
